home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CD ROM Paradise Collection 4
/
CD ROM Paradise Collection 4 1995 Nov.iso
/
system
/
ffg202.zip
/
DEMO_BAT.ZIP
/
CLEANUP.BAT
< prev
next >
Wrap
DOS Batch File
|
1995-04-01
|
1KB
|
38 lines
@echo off
if %1.==. goto USAGE:
echo Cleaning up backup and temporary files from disk drive(s) %1.
echo Searching for files to select for deletion...
ffg> cln$tmp$.bat /fb %1*[~,bak,bk!,!bk,tmp,temp,bkup]* /x*.[bat,cod]
ffg>>cln$tmp$.bat /fb %1\~trash~\*
ffg>>cln$tmp$.bat /fb %1\pdx\*.lck /d-1T
cls
echo Next you can edit out any lines with names of files you DON'T want deleted.
call presskey
edit cln$tmp$.bat
if exist cln$tmp$.bak del cln$tmp$.bak
cls
echo Press ^C to abort without deleting any files.
echo Otherwise to begin deleting files [SIMULATED]
echo.
echo The "DIR" command is used in lieu of the "DEL" command to simulate deletion.
call presskey
echo on
@call cln$tmp$ dir
@echo off
del cln$tmp$.bat
goto END
:USAGE
cls
echo USAGE: %0 d:
echo.
echo Where d: is a list of drives to clean up.
echo.
echo For example: %0 CDE: will clean up drives C:, D:, E:
echo.
echo "%0" deletes backup and temporary files. You are given an
echo opportunity to override the delete operation for specific files
echo or can abort the entire operation.
call presskey
:END